<template>
  <com-page
    :showFloatingNav="false"
    :loading="loading"
    bgColor="#ffffff"
  ></com-page>
</template>

<script lang="ts" setup>
import { ref, getCurrentInstance, computed, watch } from "vue";

import { onShow } from "@dcloudio/uni-app";

const loading = ref(true);

const { proxy } = getCurrentInstance();

watch(
  () => proxy.store.patient.list,
  (val) => {
    if (val && val.length > 0) {
      uni.switchTab({
        url: "/pages/archive/index",
      });
    }
  },
  { immediate: true }
);

// onShow(() => {
//   proxy.utils.uni.route.switchTab("/pages/archive/index");
//   // if(uni.getStorageSync("system-hospital") && uni.getStorageSync("system-dictionary") && uni.getStorageSync("system-subscription-templates") && uni.getStorageSync("system-hospital-config")){
//   // }
// });
</script>
